// index.js
// 获取应用实例
let app = getApp().globalData

Page({
  data: {
    visibleAreaRpx: 0,
    userType: null,
    loading: false
  },
  EV_loading(e) {
    console.log("ffffff",e.detail.loading);
    this.setData({
      loading:e.detail.loading
    })
  },
  onLoad() {
    console.log("可视区高度px", app.visibleAreaRpx);
    this.setData({
      visibleAreaRpx: app.visibleAreaRpx
    })
    //  检查是否登录
    if (app.userInfo == null) {
      console.log("你还未登录");
      // wx.navigateTo({
      //   url: '/pages/tologin/tologin',
      // })
    }
  },
  onShow() {
    this.setData({
      userType: app.userInfo.identity_ID
    })
  },
})